#import <Foundation/Foundation.h>
#import "XYPoint.h"
#import "Rectangle.h"

int main (int argc, const char * argv[]) {
    NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
	
	XYPoint * origin = [[XYPoint alloc] init];
	[origin setX:30 andY: 40];
	
	Rectangle * rect = [[Rectangle alloc] init];
	[rect setHeight:50 andWidth:60];
	[rect setOrigin:origin];

	NSLog(@"================= 1 ====================================");
	NSLog(@"Rect Info: --> origin:(%i, %i) height: %i width: %i", rect.origin.x, rect.origin.y, rect.height, rect.width);
	NSLog(@"Rect Area: %i", [rect area]);
	NSLog(@"Rect Perimeter: %i", [rect perimeter]);

	[origin setX:99 andY: 100];
	NSLog(@"================= 2 ====================================");
	NSLog(@"Rect Info: --> origin:(%i, %i) height: %i width: %i", rect.origin.x, rect.origin.y, rect.height, rect.width);

	[rect release];
    [pool drain];
    return 0;
}
